package com.boge.ai.entity;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import java.util.Map;

@JsonIgnoreProperties(ignoreUnknown = true)
public class Usage {
    private int prompt_tokens;
    private int completion_tokens;
    private int total_tokens;
    private Map<String, Object> completion_tokens_details;
    private Map<String, Object> prompt_tokens_details;

    // Getters and Setters
    public int getPromptTokens() { return prompt_tokens; }
    public void setPromptTokens(int prompt_tokens) { this.prompt_tokens = prompt_tokens; }

    public int getCompletionTokens() { return completion_tokens; }
    public void setCompletionTokens(int completion_tokens) { this.completion_tokens = completion_tokens; }

    public int getTotalTokens() { return total_tokens; }
    public void setTotalTokens(int total_tokens) { this.total_tokens = total_tokens; }

    public Map<String, Object> getCompletionTokensDetails() { return completion_tokens_details; }
    public void setCompletionTokensDetails(Map<String, Object> completion_tokens_details) {
        this.completion_tokens_details = completion_tokens_details;
    }

    public Map<String, Object> getPromptTokensDetails() { return prompt_tokens_details; }
    public void setPromptTokensDetails(Map<String, Object> prompt_tokens_details) {
        this.prompt_tokens_details = prompt_tokens_details;
    }

    @Override
    public String toString() {
        return "Usage{" +
                "prompt_tokens=" + prompt_tokens +
                ", completion_tokens=" + completion_tokens +
                ", total_tokens=" + total_tokens +
                ", completion_tokens_details=" + completion_tokens_details +
                ", prompt_tokens_details=" + prompt_tokens_details +
                '}';
    }
}
